//
// Map.cpp for bomberman in /home/lefebv_w//workspace/cpp/bomberman/googleCode/v1
// 
// Made by damien lefebvre
// Login   <lefebv_w@epitech.net>
// 
// Started on  Fri May  3 19:14:03 2013 damien lefebvre
// Last update Fri May  3 19:50:57 2013 damien lefebvre
//

#include	"Map.hh"

#include	<iostream>

Map::Map(void)
{
  bool	empty;
  float size;

  size = 100;

  for (int i = 0; i < 20; i++)
    {
      m_map.push_back(std::vector<Case>());
      for (int j = 0; j < 20; j++)
	{
	  if (i == 0 || i == 19 || j == 0 || j == 19 ||
	      (i == 12 && j == 12))
	    empty = false;
	  else
	    empty = true;
	  m_map[i].push_back(Case(empty, (i - 10) * size, (j - 10) * size, size));
	}
    }
}

void	Map::draw(void)
{
  for (unsigned int i = 0; i < 20; i++)
    {
      for (unsigned int j = 0; j < 20; j++)
	{
	  m_map[i][j].draw();
	}
    }
}
